<template>
  <!-- 支付宝支付界面 -->
  <div class="ali-pay box-shadow mt-4 border-radius">
    <div v-html="payInfo.codeUrl" ref="pay"></div>
  </div>
</template>
<script>
import VueCookies from 'vue-cookies'
export default {
  components: {},
  props: [],
  data() {
    return {
      payInfo: {
        codeUrl:"<form name='punchout_form' method='post' action='https://openapi.alipaydev.com/gateway.do?app_cert_sn=8661acd17b1aeaf1dc875481bfff02e4&charset=utf-8&alipay_root_cert_sn=687b59193f3f462dd5336e5abf83c5d8_02941eef3187dddf3d3b83462e1dfcf6&method=alipay.trade.page.pay&sign=GdE2nKbhqr0JqqjdF54NVEPrr%2FUOrpQsDl%2FCqhIP51%2FF7z3scWgkNpp707rzCN9x%2BSeTNmBsnRLszSxiAMMiY4ScveBDhZrzEDX3vXZqutTM%2BbrEgrmw6tZ2R7ku48dJNpEeUawBq1zFE19EMC3wbA7xfiIxv4wgcc566WJYN1sdtcpHlprFeQ9k9sc65TLt92xo0sweq9iF%2ByHdafwn5CgvsNeHR9dvB1mqa10y4lTowgkE4IsyQ6fDBdJqVY378ncJgL%2FLBhuHI16MlVWhln6mSiqUfgKXcT565FIqEuQnxR0nALYjK80F0wNR9LjIenouhL1TPzhzvN3vjo9LqA%3D%3D&version=1.0&app_id=2016102200739019&sign_type=RSA2&timestamp=2022-02-17+23%3A18%3A10&alipay_sdk=alipay-sdk-java-dynamicVersionNo&format=json'>\n" +
          "<input type='submit' value='立即支付' style='display:none' >\n" +
          "</form>"
      },
    };
  },
  mounted() {
    this.payInfo.codeUrl = VueCookies.get("payForm");
    this.$nextTick(() => {
      this.$refs.pay.children[0].submit();
    });
  },
  methods: {},
};
</script>
